<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
<html>
<head>
	<title>API: element  YAHOO.util.AttributeProvider   (YUI Library)</title>
	<link rel="stylesheet" type="text/css" href="assets/api.css">
</head>

<body id="yahoo-com">
<div id="doc3" class="yui-t2">

	<div id="hd">
        <h1>Yahoo! UI Library</h1>
        <h3>element&nbsp; <span class="subtitle">2.2.2</span></h3>
        <p>
        <a href="./index.html">Yahoo! UI Library</a> 
            &gt; <a href="./module_element.html">element</a>
                 &gt; YAHOO.util.AttributeProvider 
                
            </p>
	</div>

	<div id="bd">
		<div id="yui-main">
			<div class="yui-b">


                    <h2>
                        

                        
                        
                            Class <b>YAHOO.util.AttributeProvider</b>
                        <span class="extends">
                        </span>

                        <span class="extends">
                          - uses 
                            
                                <a href="YAHOO.util.EventProvider.html">YAHOO.util.EventProvider</a>
                            
                        </span>
                        
                        </code>
                    </h2>
                    <!-- class tree goes here -->
                    
                
  

                    <div class="summary description">
                        Provides and manages YAHOO.util.Attribute instances
                    </div>


                        <div class="section field details">
                            <h3><a name="field_detail">Properties</a></h3>
                            <div class="content">
                                    <h4><a name="_configs">_configs</a>
                                        <code>- private {Object}</code>
                                    </h4>
                                    <div class="detail">
                                        <div class="description">
                                            A key-value map of Attribute configurations
                                        </div>
                                    </div>
     
                                        


                                    <hr />


                            </div>
                        </div>

                        <div class="section field inheritance">
                            <h4>Properties inherited from <a href="YAHOO.util.EventProvider.html">YAHOO.util.EventProvider</a>:</h4>
                            <div class="content">
                                <code>
                                    
                                        <a href="YAHOO.util.EventProvider.html#__yui_events">__yui_events</a>,
                                        <a href="YAHOO.util.EventProvider.html#__yui_subscribers">__yui_subscribers</a>
                                </code>
                            </div>
                        </div>

                        <div class="section method details">
                            <h3><a name="methodDetails">Methods</a></h3>
                            <div class="content">
                                    <h4>
                                        <a name="configureAttribute">configureAttribute</a></h4>
                                    <div class="detail">
                                        <code>
                                        
                                        
                                        
                                        void
                                            <strong>configureAttribute</strong>
                                           (
                                                
                                                        
                                                         key
                                                    
                                                
                                                        , 
                                                         map
                                                    
                                                
                                                        , 
                                                         init
                                                    
                                                
                                            )
                                        </code>
                                        
                                        <div class="description">
                                            Sets or updates an Attribute instance's properties.
                                        </div>

                                        <div class="description">

                                                <dl>
                                                    <dt>Parameters:</dt>
                                                        <dd>
                                                            <code>key &lt;String&gt;</code>
                                                             The attribute's name.
                                                        </dd>
                                                        <dd>
                                                            <code>map &lt;Object&gt;</code>
                                                             A key-value map of attribute properties
                                                        </dd>
                                                        <dd>
                                                            <code>init &lt;Boolean&gt;</code>
                                                             Whether or not this should become the intial config.
                                                        </dd>
                                                </dl>

                                                <dl>
                                                    <dt>Returns:
                                                    <code>
                                                        void
                                                    </code></dt>
                                                    <dd></dd>
                                                </dl>
             
                                            <div class="deprecated">
                                                <strong>Deprecated</strong> Use setAttributeConfig
                                            </div>        
                                        </div>

                                    </div>
                                    <hr />
                                    <h4>
                                        <a name="fireBeforeChangeEvent">fireBeforeChangeEvent</a></h4>
                                    <div class="detail">
                                        <code>
                                        
                                        
                                        
                                        void
                                            <strong>fireBeforeChangeEvent</strong>
                                           (
                                                
                                                        
                                                         key
                                                    
                                                
                                                        , 
                                                         e
                                                    
                                                
                                            )
                                        </code>
                                        
                                        <div class="description">
                                            Fires the attribute's beforeChange event.
                                        </div>

                                        <div class="description">

                                                <dl>
                                                    <dt>Parameters:</dt>
                                                        <dd>
                                                            <code>key &lt;String&gt;</code>
                                                             The attribute's name.
                                                        </dd>
                                                        <dd>
                                                            <code>e &lt;Obj&gt;</code>
                                                             The event object to pass to handlers.
                                                        </dd>
                                                </dl>

                                                <dl>
                                                    <dt>Returns:
                                                    <code>
                                                        void
                                                    </code></dt>
                                                    <dd></dd>
                                                </dl>
             
                                        </div>

                                    </div>
                                    <hr />
                                    <h4>
                                        <a name="fireChangeEvent">fireChangeEvent</a></h4>
                                    <div class="detail">
                                        <code>
                                        
                                        
                                        
                                        void
                                            <strong>fireChangeEvent</strong>
                                           (
                                                
                                                        
                                                         key
                                                    
                                                
                                                        , 
                                                         e
                                                    
                                                
                                            )
                                        </code>
                                        
                                        <div class="description">
                                            Fires the attribute's change event.
                                        </div>

                                        <div class="description">

                                                <dl>
                                                    <dt>Parameters:</dt>
                                                        <dd>
                                                            <code>key &lt;String&gt;</code>
                                                             The attribute's name.
                                                        </dd>
                                                        <dd>
                                                            <code>e &lt;Obj&gt;</code>
                                                             The event object to pass to the handlers.
                                                        </dd>
                                                </dl>

                                                <dl>
                                                    <dt>Returns:
                                                    <code>
                                                        void
                                                    </code></dt>
                                                    <dd></dd>
                                                </dl>
             
                                        </div>

                                    </div>
                                    <hr />
                                    <h4>
                                        <a name="get">get</a></h4>
                                    <div class="detail">
                                        <code>
                                        
                                        
                                        
                                        void
                                            <strong>get</strong>
                                           (
                                                
                                                        
                                                         key
                                                    
                                                
                                            )
                                        </code>
                                        
                                        <div class="description">
                                            Returns the current value of the attribute.
                                        </div>

                                        <div class="description">

                                                <dl>
                                                    <dt>Parameters:</dt>
                                                        <dd>
                                                            <code>key &lt;String&gt;</code>
                                                             The attribute whose value will be returned.
                                                        </dd>
                                                </dl>

                                                <dl>
                                                    <dt>Returns:
                                                    <code>
                                                        void
                                                    </code></dt>
                                                    <dd></dd>
                                                </dl>
             
                                        </div>

                                    </div>
                                    <hr />
                                    <h4>
                                        <a name="getAttributeConfig">getAttributeConfig</a></h4>
                                    <div class="detail">
                                        <code>
                                         private 
                                        
                                        
                                        object
                                            <strong>getAttributeConfig</strong>
                                           (
                                                
                                                        
                                                         key
                                                    
                                                
                                            )
                                        </code>
                                        
                                        <div class="description">
                                            Returns the attribute's properties.
                                        </div>

                                        <div class="description">

                                                <dl>
                                                    <dt>Parameters:</dt>
                                                        <dd>
                                                            <code>key &lt;String&gt;</code>
                                                             The attribute's name
                                                        </dd>
                                                </dl>

                                                <dl>
                                                    <dt>Returns:
                                                    <code>
                                                        object
                                                    </code></dt>
                                                    <dd>A key-value map containing all of the
attribute's properties.</dd>
                                                </dl>
             
                                        </div>

                                    </div>
                                    <hr />
                                    <h4>
                                        <a name="getAttributeKeys">getAttributeKeys</a></h4>
                                    <div class="detail">
                                        <code>
                                        
                                        
                                        
                                        Array
                                            <strong>getAttributeKeys</strong>
                                           (
                                            )
                                        </code>
                                        
                                        <div class="description">
                                            Returns an array of attribute names.
                                        </div>

                                        <div class="description">


                                                <dl>
                                                    <dt>Returns:
                                                    <code>
                                                        Array
                                                    </code></dt>
                                                    <dd>An array of attribute names.</dd>
                                                </dl>
             
                                        </div>

                                    </div>
                                    <hr />
                                    <h4>
                                        <a name="refresh">refresh</a></h4>
                                    <div class="detail">
                                        <code>
                                        
                                        
                                        
                                        void
                                            <strong>refresh</strong>
                                           (
                                                
                                                        
                                                         key
                                                    
                                                
                                                        , 
                                                         silent
                                                    
                                                
                                            )
                                        </code>
                                        
                                        <div class="description">
                                            Sets the attribute's value to its current value.
                                        </div>

                                        <div class="description">

                                                <dl>
                                                    <dt>Parameters:</dt>
                                                        <dd>
                                                            <code>key &lt;String | Array&gt;</code>
                                                             The attribute(s) to refresh
                                                        </dd>
                                                        <dd>
                                                            <code>silent &lt;Boolean&gt;</code>
                                                             Whether or not to suppress change events
                                                        </dd>
                                                </dl>

                                                <dl>
                                                    <dt>Returns:
                                                    <code>
                                                        void
                                                    </code></dt>
                                                    <dd></dd>
                                                </dl>
             
                                        </div>

                                    </div>
                                    <hr />
                                    <h4>
                                        <a name="register">register</a></h4>
                                    <div class="detail">
                                        <code>
                                        
                                        
                                        
                                        void
                                            <strong>register</strong>
                                           (
                                                
                                                        
                                                         key
                                                    
                                                
                                                        , 
                                                         map
                                                    
                                                
                                            )
                                        </code>
                                        
                                        <div class="description">
                                            Adds an Attribute to the AttributeProvider instance.
                                        </div>

                                        <div class="description">

                                                <dl>
                                                    <dt>Parameters:</dt>
                                                        <dd>
                                                            <code>key &lt;String&gt;</code>
                                                             The attribute's name
                                                        </dd>
                                                        <dd>
                                                            <code>map &lt;Object&gt;</code>
                                                             A key-value map containing the
attribute's properties.
                                                        </dd>
                                                </dl>

                                                <dl>
                                                    <dt>Returns:
                                                    <code>
                                                        void
                                                    </code></dt>
                                                    <dd></dd>
                                                </dl>
             
                                            <div class="deprecated">
                                                <strong>Deprecated</strong> Use setAttributeConfig
                                            </div>        
                                        </div>

                                    </div>
                                    <hr />
                                    <h4>
                                        <a name="resetAttributeConfig">resetAttributeConfig</a></h4>
                                    <div class="detail">
                                        <code>
                                         private 
                                        
                                        
                                        void
                                            <strong>resetAttributeConfig</strong>
                                           (
                                                
                                                        
                                                         key
                                                    
                                                
                                            )
                                        </code>
                                        
                                        <div class="description">
                                            Resets an attribute to its intial configuration.
                                        </div>

                                        <div class="description">

                                                <dl>
                                                    <dt>Parameters:</dt>
                                                        <dd>
                                                            <code>key &lt;String&gt;</code>
                                                             The attribute's name.
                                                        </dd>
                                                </dl>

                                                <dl>
                                                    <dt>Returns:
                                                    <code>
                                                        void
                                                    </code></dt>
                                                    <dd></dd>
                                                </dl>
             
                                        </div>

                                    </div>
                                    <hr />
                                    <h4>
                                        <a name="resetValue">resetValue</a></h4>
                                    <div class="detail">
                                        <code>
                                        
                                        
                                        
                                        Boolean
                                            <strong>resetValue</strong>
                                           (
                                                
                                                        
                                                         key
                                                    
                                                
                                                        , 
                                                         silent
                                                    
                                                
                                            )
                                        </code>
                                        
                                        <div class="description">
                                            Resets the specified attribute's value to its initial value.
                                        </div>

                                        <div class="description">

                                                <dl>
                                                    <dt>Parameters:</dt>
                                                        <dd>
                                                            <code>key &lt;String&gt;</code>
                                                             The name of the attribute
                                                        </dd>
                                                        <dd>
                                                            <code>silent &lt;Boolean&gt;</code>
                                                             Whether or not to suppress change events
                                                        </dd>
                                                </dl>

                                                <dl>
                                                    <dt>Returns:
                                                    <code>
                                                        Boolean
                                                    </code></dt>
                                                    <dd>Whether or not the value was set</dd>
                                                </dl>
             
                                        </div>

                                    </div>
                                    <hr />
                                    <h4>
                                        <a name="set">set</a></h4>
                                    <div class="detail">
                                        <code>
                                        
                                        
                                        
                                        Boolean
                                            <strong>set</strong>
                                           (
                                                
                                                        
                                                         key
                                                    
                                                
                                                        , 
                                                         value
                                                    
                                                
                                                        , 
                                                         silent
                                                    
                                                
                                            )
                                        </code>
                                        
                                        <div class="description">
                                            Sets the value of a config.
                                        </div>

                                        <div class="description">

                                                <dl>
                                                    <dt>Parameters:</dt>
                                                        <dd>
                                                            <code>key &lt;String&gt;</code>
                                                             The name of the attribute
                                                        </dd>
                                                        <dd>
                                                            <code>value &lt;Any&gt;</code>
                                                             The value to apply to the attribute
                                                        </dd>
                                                        <dd>
                                                            <code>silent &lt;Boolean&gt;</code>
                                                             Whether or not to suppress change events
                                                        </dd>
                                                </dl>

                                                <dl>
                                                    <dt>Returns:
                                                    <code>
                                                        Boolean
                                                    </code></dt>
                                                    <dd>Whether or not the value was set.</dd>
                                                </dl>
             
                                        </div>

                                    </div>
                                    <hr />
                                    <h4>
                                        <a name="setAttributeConfig">setAttributeConfig</a></h4>
                                    <div class="detail">
                                        <code>
                                        
                                        
                                        
                                        void
                                            <strong>setAttributeConfig</strong>
                                           (
                                                
                                                        
                                                         key
                                                    
                                                
                                                        , 
                                                         map
                                                    
                                                
                                                        , 
                                                         init
                                                    
                                                
                                            )
                                        </code>
                                        
                                        <div class="description">
                                            Sets or updates an Attribute instance's properties.
                                        </div>

                                        <div class="description">

                                                <dl>
                                                    <dt>Parameters:</dt>
                                                        <dd>
                                                            <code>key &lt;String&gt;</code>
                                                             The attribute's name.
                                                        </dd>
                                                        <dd>
                                                            <code>map &lt;Object&gt;</code>
                                                             A key-value map of attribute properties
                                                        </dd>
                                                        <dd>
                                                            <code>init &lt;Boolean&gt;</code>
                                                             Whether or not this should become the intial config.
                                                        </dd>
                                                </dl>

                                                <dl>
                                                    <dt>Returns:
                                                    <code>
                                                        void
                                                    </code></dt>
                                                    <dd></dd>
                                                </dl>
             
                                        </div>

                                    </div>
                                    <hr />
                                    <h4>
                                        <a name="setAttributes">setAttributes</a></h4>
                                    <div class="detail">
                                        <code>
                                        
                                        
                                        
                                        void
                                            <strong>setAttributes</strong>
                                           (
                                                
                                                        
                                                         map
                                                    
                                                
                                                        , 
                                                         silent
                                                    
                                                
                                            )
                                        </code>
                                        
                                        <div class="description">
                                            Sets multiple attribute values.
                                        </div>

                                        <div class="description">

                                                <dl>
                                                    <dt>Parameters:</dt>
                                                        <dd>
                                                            <code>map &lt;Object&gt;</code>
                                                              A key-value map of attributes
                                                        </dd>
                                                        <dd>
                                                            <code>silent &lt;Boolean&gt;</code>
                                                             Whether or not to suppress change events
                                                        </dd>
                                                </dl>

                                                <dl>
                                                    <dt>Returns:
                                                    <code>
                                                        void
                                                    </code></dt>
                                                    <dd></dd>
                                                </dl>
             
                                        </div>

                                    </div>
                                    <hr />
                            </div>
                        </div>

                            <div class="section field inheritance">
                                <h4>Methods inherited from <a href="YAHOO.util.EventProvider.html">YAHOO.util.EventProvider</a>:</h4>
                                <div class="content">
                                    <code>
                                        
                                            <a href="YAHOO.util.EventProvider.html#createEvent">createEvent</a>,
                                            <a href="YAHOO.util.EventProvider.html#fireEvent">fireEvent</a>,
                                            <a href="YAHOO.util.EventProvider.html#hasEvent">hasEvent</a>,
                                            <a href="YAHOO.util.EventProvider.html#subscribe">subscribe</a>,
                                            <a href="YAHOO.util.EventProvider.html#unsubscribe">unsubscribe</a>,
                                            <a href="YAHOO.util.EventProvider.html#unsubscribeAll">unsubscribeAll</a>
                                    </code>
                                </div>
                            </div>






			</div>
		</div>
		<div class="yui-b">
            <div class="nav">

                    <div class="module">
                        <h4>Modules</h4>
                        <ul class="content">

                                <li class=""><a href="module_animation.html">animation</a></li>

                                <li class=""><a href="module_autocomplete.html">autocomplete</a></li>

                                <li class=""><a href="module_button.html">button</a></li>

                                <li class=""><a href="module_calendar.html">calendar</a></li>

                                <li class=""><a href="module_connection.html">connection</a></li>

                                <li class=""><a href="module_container.html">container</a></li>

                                <li class=""><a href="module_datasource.html">datasource</a></li>

                                <li class=""><a href="module_datatable.html">datatable</a></li>

                                <li class=""><a href="module_dom.html">dom</a></li>

                                <li class=""><a href="module_dragdrop.html">dragdrop</a></li>

                                <li class="selected"><a href="module_element.html">element</a></li>

                                <li class=""><a href="module_event.html">event</a></li>

                                <li class=""><a href="module_history.html">history</a></li>

                                <li class=""><a href="module_logger.html">logger</a></li>

                                <li class=""><a href="module_menu.html">menu</a></li>

                                <li class=""><a href="module_slider.html">slider</a></li>

                                <li class=""><a href="module_tabview.html">tabview</a></li>

                                <li class=""><a href="module_treeview.html">treeview</a></li>

                                <li class=""><a href="module_yahoo.html">yahoo</a></li>
                        </ul>
                    </div>

                    <div class="module">
                        <h4>Classes</h4>
                        <ul class="content">
                                <li class=""><a href="YAHOO.util.Attribute.html">YAHOO.util.Attribute</a></li>
                                <li class="selected"><a href="YAHOO.util.AttributeProvider.html">YAHOO.util.AttributeProvider</a></li>
                                <li class=""><a href="YAHOO.util.Element.html">YAHOO.util.Element</a></li>
                        </ul>
                    </div>

                    <div class="module">
                        <h4>Files</h4>
                        <ul class="content">        
                                <li class=""><a href="Attribute.js.html">Attribute.js</a></li>
                                <li class=""><a href="AttributeProvider.js.html">AttributeProvider.js</a></li>
                                <li class=""><a href="Element.js.html">Element.js</a></li>
                        </ul>
                    </div>

                    <div class="module">
                        <h4>Properties</h4>
                        <ul class="content">        
                                <li><a href="#_configs">_configs</a>
                                        <!--<code>&lt;{Object}&gt;</code>-->
                                </li>
                        </ul>
                    </div>

                    <div class="module">
                        <h4>Methods</h4>
                        <ul class="content">        
                                <li><!--<code>void</code>-->
                                <a href="#configureAttribute">configureAttribute</a>
                                </li>
                                <li><!--<code>void</code>-->
                                <a href="#fireBeforeChangeEvent">fireBeforeChangeEvent</a>
                                </li>
                                <li><!--<code>void</code>-->
                                <a href="#fireChangeEvent">fireChangeEvent</a>
                                </li>
                                <li><!--<code>void</code>-->
                                <a href="#get">get</a>
                                </li>
                                <li><!--<code>object</code>-->
                                <a href="#getAttributeConfig">getAttributeConfig</a>
                                </li>
                                <li><!--<code>Array</code>-->
                                <a href="#getAttributeKeys">getAttributeKeys</a>
                                </li>
                                <li><!--<code>void</code>-->
                                <a href="#refresh">refresh</a>
                                </li>
                                <li><!--<code>void</code>-->
                                <a href="#register">register</a>
                                </li>
                                <li><!--<code>void</code>-->
                                <a href="#resetAttributeConfig">resetAttributeConfig</a>
                                </li>
                                <li><!--<code>Boolean</code>-->
                                <a href="#resetValue">resetValue</a>
                                </li>
                                <li><!--<code>Boolean</code>-->
                                <a href="#set">set</a>
                                </li>
                                <li><!--<code>void</code>-->
                                <a href="#setAttributeConfig">setAttributeConfig</a>
                                </li>
                                <li><!--<code>void</code>-->
                                <a href="#setAttributes">setAttributes</a>
                                </li>
                        </ul>
                    </div>



            </div>
		</div>
	</div>
	<div id="ft">
        <hr />
        Copyright &copy; 2007 Yahoo! Inc. All rights reserved.
	</div>
</div>
</body>
</html>
